﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Site.master" AutoEventWireup="true" CodeFile="employee.aspx.cs" Inherits="employee" %>
<%@ Register assembly="AjaxControlToolkit" namespace="AjaxControlToolkit" tagprefix="asp" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
<div class="main">
    <asp:UpdatePanel ID="UpdateTable" runat="server">
        <ContentTemplate>
        
    <div class="filter">
    <table style="width: 100%;">
        <tr>
            <td>
               Emp Code
            </td>
            <td>
                <asp:TextBox ID="txtEmpCode" runat="server" Width="150px" CssClass="txt"></asp:TextBox>
            </td>
            <td>
                Department
            </td>
             <td>
                  <asp:DropDownList ID="ddlDepartment" runat="server" Width="158px" 
                      AutoPostBack="True" DataTextField="DeptName" DataValueField="DeptCode" 
                      onselectedindexchanged="ddlDepartment_SelectedIndexChanged" CssClass="txt">
                </asp:DropDownList>
            </td>
            <td>
               Join Date To
            </td>
            <td>
                <asp:TextBox ID="txtJoinDateTo" runat="server" Width="80px" CssClass="txt"></asp:TextBox>
                <asp:CalendarExtender ID="txtJoinDateTo_CalendarExtender" runat="server" 
                    Enabled="True" TargetControlID="txtJoinDateTo" CssClass="orange">
                </asp:CalendarExtender>
            </td>
            <td>
               Join Date From</td>
            <td>
                <asp:TextBox ID="txtJoinDateFrom" runat="server" Width="80px" CssClass="txt"></asp:TextBox>
                <asp:CalendarExtender ID="txtJoinDateFrom_CalendarExtender" runat="server" 
                    Enabled="True" TargetControlID="txtJoinDateFrom" CssClass="orange">
                </asp:CalendarExtender>
            </td>
        </tr>
       <tr>
            <td>
              FirstName
            </td>
            <td>
               <asp:TextBox ID="txtFirstName" runat="server" Width="150px" CssClass="txt"></asp:TextBox>
            </td>
            <td>
               Section Name
            </td>
             <td>
                 <asp:DropDownList ID="ddlSectionName" runat="server" Width="158px" 
                     DataTextField="SectionName" DataValueField="SectionCode" CssClass="txt">
                </asp:DropDownList>
            </td>
            <td>
               &nbsp;Birth Day From
            </td>
            <td>
                 <asp:TextBox ID="txtBirthDayFrom" runat="server" Width="80px" CssClass="txt"></asp:TextBox>
                 <asp:CalendarExtender ID="txtBirthDayFrom_CalendarExtender" runat="server" 
                     Enabled="True" TargetControlID="txtBirthDayFrom" CssClass="orange">
                 </asp:CalendarExtender>
            </td>
            <td>
                Birth Day To
            </td>
            <td>
                <asp:TextBox ID="txtBirthDayTo" runat="server" Width="80px" CssClass="txt"></asp:TextBox>
                <asp:CalendarExtender ID="txtBirthDayTo_CalendarExtender" runat="server" 
                    Enabled="True" TargetControlID="txtBirthDayTo" CssClass="orange">
                </asp:CalendarExtender>
            </td>
        </tr>
        <tr>
            <td>
               LastName
            </td>
            <td>
                <asp:TextBox ID="txtLastName" runat="server" Width="150px" CssClass="txt"></asp:TextBox>
            </td>
            <td>
                &nbsp;</td>
             <td>
                 &nbsp;</td>
            <td>
                &nbsp;</td>
            <td>
                &nbsp;</td>
            <td>
                &nbsp;</td>
            <td>
                &nbsp;</td>
        </tr>
    </table>
    <div class="submit border_top">
        <input id="btnClear" type="submit" value="Clear" class="btngray"/>
        <asp:Button ID="btnFilter" runat="server" Text="Filter" CssClass="btnOrage" 
            onclick="btnFilter_Click"/>
    </div>
</div>

<div class="list">
    <div class="scroll_ngang">
       <div class="scroll_doc">
           <div class="body_table" style="width:1500px;">
               <asp:GridView ID="grvData" runat="server" AutoGenerateColumns="False" 
                   AllowPaging="True" onpageindexchanged="grvData_PageIndexChanged" 
                   onpageindexchanging="grvData_PageIndexChanging" 
                   onselectedindexchanged="grvData_SelectedIndexChanged" 
                   onselectedindexchanging="grvData_SelectedIndexChanging" PageSize="15" 
                   ShowHeaderWhenEmpty="True" EmptyDataText="No data" >
                   <Columns>
                       <asp:BoundField DataField="EmpCode" HeaderText="Emp Code" FooterText="Total :" >
                       <ItemStyle Width="70px" />
                       </asp:BoundField>
                       <asp:BoundField DataField="LastName" HeaderText="Last Name" >
                       <ItemStyle Width="250px" HorizontalAlign="Left"/>
                       </asp:BoundField>
                       <asp:BoundField DataField="FirstName" HeaderText="First Name" >
                       <ItemStyle Width="250px" HorizontalAlign="Left"/>
                       </asp:BoundField>
                       
                        <asp:TemplateField HeaderText="Male" >
                            <ItemTemplate >
                                <asp:CheckBox ID="chkcheckuser" runat="server" Checked='<%# Eval("Male") %>' Enabled="false"></asp:CheckBox>
                                
                            </ItemTemplate>
                            <ItemStyle HorizontalAlign="Center" Width="40px" />
                        </asp:TemplateField>
                       <asp:BoundField DataField="BirthDay_format" HeaderText="Birth Day" 
                           DataFormatString="{0:dd/MM/yyyy}" >
                       <ItemStyle Width="100px" />
                       </asp:BoundField>
                       <asp:BoundField DataField="EmailAddress" HeaderText="Email" >
                       <ItemStyle Width="170px" />
                       </asp:BoundField>
                       <asp:BoundField DataField="JoinDate" HeaderText="Join Date" 
                           DataFormatString="{0:dd/MM/yyyy}" >
                       <HeaderStyle Width="120px" />
                       </asp:BoundField>
                       <asp:BoundField DataField="BenefitStartDate" HeaderText="Benefit Start Date" 
                           DataFormatString="{0:dd/MM/yyyy}" >
                       <ItemStyle Width="200px" />
                       </asp:BoundField>
                       <asp:BoundField DataField="DeptName" HeaderText="Dept Name" >
                       <ItemStyle Width="150px" />
                       </asp:BoundField>
                       <asp:BoundField DataField="SectionName" HeaderText="Section Name" >
                       <ItemStyle Width="250px" />
                       </asp:BoundField>
                       <asp:BoundField DataField="WorkPlaceName" HeaderText="Work Place Name" >
                       <ItemStyle Width="400px" />
                       </asp:BoundField>
                       <asp:BoundField DataField="TimeCardNo" HeaderText="Time Card No" >
                       <ItemStyle Width="200px" />
                       </asp:BoundField>
                   </Columns>

                   <SelectedRowStyle BackColor="#99FFCC" />

               </asp:GridView>
               
           </div><!-- body -->
           
       </div><!-- doc -->

   </div><!-- ngang -->
   <div style="width:100%;text-align:right;color:#008082;font-weight:bold;font-size:1.2em;">
   <asp:Label ID="lbTotal" runat="server" Text=""></asp:Label>
   </div>
   
   <div class="foot_table">
   
   </div>
</div>
</ContentTemplate>
</asp:UpdatePanel>
     <asp:UpdateProgress ID="UpadateProc" AssociatedUpdatePanelID="UpdateTable" runat="server">
     <ProgressTemplate>
             <div class="loading">

                 <img src="resources/images/process_small2.gif" alt=""/>
            </div>
    </ProgressTemplate>
</asp:UpdateProgress>
</div>
</asp:Content>

